import type { Response_Dto } from '@/Dto/Response/Api_Result'
import request from '@/utils/request'

export const GetAllVipType=(obj:{page:number,limit:number,key:string}):Promise<Response_Dto>=>{
    return request({
        url: 'api/vip/GetAllVIP',
        method: 'get',
        params: obj
    })
}
export const UpdateVIP=(obj:{id:string,effectivetime:Int16Array,did:string}):Promise<Response_Dto>=>{

    return request({
        url: 'api/vip/UpdateVIP',
        method: 'post',
        data: obj
    })
}
export const GetVIPTypeById = (obj: { id: string }): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/GetVIPTypeById',
        method: 'get',
        params: obj
    })
}

export const AddVIP = (obj: { name: string, address: string, qq: string, wx: string, school: string, phone: Int16Array, responsibility: string }): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/AddVIP',
        method: 'post',
        data: obj
    })
}

export const GetLastYearVIPAdd = (obj: {}): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/GetLastYearVIPAdd',
        method: 'get',
        params: obj
    })
}

export const GetLastYearRecharge = (obj: {}): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/GetLastYearRecharge',
        method: 'get',
        params: obj
    })
}
export const BindTodayData = (obj: {}): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/BindTodayData',
        method: 'get',
        params: obj
    })
}
export const GetUserRechargeByid = (obj: { id: string }): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/GetUserRechargeByid',
        method: 'get',
        params: obj
    })
}
export const VIPRecharge=(obj:{cid:string,money:Int16Array}):Promise<Response_Dto>=>{
    return request({
        url: 'api/vip/Recharge',
        method: 'post',
        data: obj
    })
}
export const AddVIPType = (obj: { name: string, value: string, desc: string, explain: string }): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/AddVIPType',
        method: 'post',
        data: obj
    })
}


export const DeleteVIPType = (obj: { id: string }): Promise<Response_Dto> => {
    return request({
        url: 'api/vip/DeleteVIPType',
        method: 'post',
        data: obj
    })
}

export const BindSale=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/BindSale',
        method:'get',
        params:obj
    })
}
export const bindvipcount=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/bindvipcount',
        method:'get',
        params:obj
    })
}
export const bindactive=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/bindactive',
        method:'get',
        params:obj
    })
}
export const bindconsumption=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/bindconsumption',
        method:'get',
        params:obj
    })
}

export const bindactiveEcharts=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/bindactiveEcharts',
        method:'get',
        params:obj
    })
}

export const ExpireVIP=(obj:{id:string}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/ExpireVIP',
        method:'post',
        data:obj
    })
}

export const hfvip=(obj:{id:string,effectivetime:int}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/hfvip',
        method:'post',
        data:obj
    })
}

export const gethycard=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/gethycard',
        method:'get',
        params:obj
    })
}
export const getexpirehycard=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/getexpirehycard',
        method:'get',
        params:obj
    })
}

export const getbesthy=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/getbesthy',
        method:'get',
        params:obj
    })
}

export const getmincard=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/getmincard',
        method:'get',
        params:obj
    })
}

export const bestuser=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/bestuser',
        method:'get',
        params:obj
    })
}

export const todayRecharge=(obj:{}):Promise<Response_Dto>=>{
    return request({
        url:'api/vip/todayRecharge',
        method:'get',
        params:obj
    })
}